home *** CD-ROM | disk | FTP | other *** search
/ Software Vault: The Gold Collection / Software Vault - The Gold Collection (American Databankers) (1993).ISO / cdr50 / qbmenu10.zip / SAVESCRN.BI < prev   
Text File  |  1993-06-21  |  2KB  |  52 lines

  1. ' INCLUDE file for SaveScreen Library
  2. '  by Victor Yiu
  3.  
  4. DECLARE FUNCTION Snatch% (Saved%(), StartX%, StartY%, EndX%, EndY%, Func%)
  5.  
  6. CONST Save = 1, Rest = 2
  7.  
  8. ' set the length accordingly to required size
  9.  
  10. '   NOTE: !!!!!! To change the size of the stack, increase or decrease
  11. '       the number in "CONST SetSTACKsize = xxx"  Usually, 8000 bytes
  12. '       is enough for most applications.  A whole 80x25 screen will occupy
  13. '       4000 bytes of the stack.
  14.  
  15. CONST SetSTACKsize = 7000
  16.       ' change here: ^^^^
  17.  
  18. 'DIM SHARED Saved%()
  19. DIM SHARED Saved%(1 TO (SetSTACKsize \ 2))
  20.  
  21. '   Snatch is a FUNCTION.  Always pass the array dimensioned in this
  22. '   include file.  DO NOT ERASE OR REDIMension THE ARRAY.
  23. '                   ** THE PROGRAM MAY CRASH! **
  24. '
  25. '   At the beginning of your program, you must initialize SNATCH.  Do so
  26. '   by calling it like this:
  27. '
  28. '           Dummy = Snatch (Saved%(), 0, 0, 0, 0, 0)
  29. '   If you want to adjust the number of screensaves possible from the default
  30. '   10, then replace the 1st 0 with it.  If the display being used is a
  31. '   monocrome VGA, then replace the 2nd "0" with any other # besides 0.
  32. '   If you want a queue of 20 using a mono VGA system:
  33. '
  34. '           Dummy = Snatch (Saved%(), 20, 1, 0, 0, 0)
  35. '
  36. '---->  Now, on with the works.
  37. '
  38. '   Next, you pass the address of the screen to save:
  39. '       startX, startY, endX, endY
  40. '         i.e.:   1, 1, 80, 25
  41. '                  that will save the whole screen (assuming it is 80x25)
  42. '
  43. '   Last, you pass the function, either "Save," "Rest," "Move," or "MoveKeep."
  44. '       Use SAVE to store the screen, Rest to restore the screen.  You do
  45. '       not have to pass the screen co-ordinates during in REST.  It is
  46. '       automatically stored.
  47. '
  48. '  Since SNATCH is a function, it will return TRUE if sucessful, FALSE if not
  49. '
  50. '  Have fun with this ULTRA-FAST save/restore routine!!!!
  51.  
  52.